package com.hjt.zhibo.app;

import javax.servlet.ServletContext;

import jodd.madvoc.WebApplication;
import jodd.madvoc.component.MadvocConfig;
import jodd.upload.impl.AdaptiveFileUploadFactory;

public class MyWebApplication extends WebApplication{

	@Override
    public void registerMadvocComponents() {
        super.registerMadvocComponents();
        registerComponent(MyMadvocConfig.class);
    }

    @Override
    protected void init(MadvocConfig madvocConfig, ServletContext servletContext) {
        ((AdaptiveFileUploadFactory) madvocConfig.getFileUploadFactory())
        .setBreakOnError(true);
    }
	
}
